Bluetooth Low Energy (BLE) also known as Bluetooth Smart or Version 4.0+ of the Bluetooth specification is the next generation of Bluetooth protocol designed for low power applications such as consumer devices (headphones, keyboards, security devices, appliances, etc.), Internet of Things (IoT), and the like. BLE is designed and optimized for low cost, low bandwidth, low power, and low complexity to provide considerably low power consumption compared to the classic Bluetooth while supporting similar communication range as the classic Bluetooth. The power-efficiency of BLE makes it suitable for devices that run for long periods on low power sources such as coin cell batteries or energy-harvesting devices.
To establish a BLE connection, a BLE enabled device (also known as peripheral device) has to be in advertising or slave mode and broadcast advertisement packets to allow for a connection with another device. The other device has to be in an Initiator or Host mode to accept the advertising packets and establish a connection with the BLE enabled device. For example, a BLE enabled headphone or keyboard will advertise its ability to make connection with a device such as a music player or computer by broadcasting advertisement packets. When the music player or computer receives the advertisement packets, it will establish a connection with the headphone or the keyboard. The host devices (e.g., music player, computer, or the like) scan for advertisement packets from a BLE enabled peripheral device and after receiving an advertisement packet, they send a connection request to the BLE enabled peripheral device. Once a connection is established, the host device assumes the role of master device and the BLE advertiser becomes a Slave device. Slave devices may have only one connection at a time with a host device while master devices may have multiple connections with different slave devices simultaneously.
When a slave device sends advertisement packets then it gets into a connection acceptance mode meaning it is ready to accept a connection from a host. Thus, any host in the communication range who receives the advertisement packet from the slave device can establish a connection with the slave device whether the host is the right device or not. For example, if a headphone initiates advertisement packets to connect to a host, then it is probably looking for a music player to connect with; however, if another host device such as for example, a computer receives the advertisement packets and sends a connection request to the headphone, then the headphone will have to accept the connection and will be connected to the computer. The slave device does not have the control over which paired master device it will connect to without using the so called directed advertisement.
In directed advertisement method, a slave device sends advertisement packets directed to a specific host address and only the specific host identified by the address in the directed advertisement, responds to the advertisement packet and connects to the slave/peripheral device. Even in the directed advertisement method, the slave/peripheral device does not have any control over the connection and if a host, which is not identified in the advertisement packet, initiates a connection with the slave/peripheral device in response to the advertisement packet, then the slave/peripheral device assumes that the host is the specific host it identified in its advertisement packet and connects to the host. In the previous example, if a headphone sends directed advertisement packets addressing to a music player and instead a computer initiates a connection with the headphone, then headphone has no control over the connection and will end up connecting with the computer.
Further, due to various security reasons, host devices routinely change their address to avoid being targeted by malicious hacking attacks. In such case, a slave/peripheral device such as a BLE slave/peripheral device, has no way to know the new host address especially, when the BLE slave/peripheral device wakes up from an inactive or sleep state and tries to look for the host it was connected to earlier (by sending directed advertisement). This may result in the BLE slave device's advertisements not detected by the correct host (loosing connection with the correct host) or get connected to a wrong host.